<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta charset="utf-8">
<title>销售查询</title>
<body>

<div class="container">
<%@include file="head.jsp"%>
<%@include file="left.jsp"%>
 <div class="right-menu">
  <div class="main-hd">
   <div class="page-teb" >
    <div class="l-tab-links">
     <ul style="left:0;">
      <li class="l-select">
       <a href="<%=basePath%>index.jsp" style="padding:0px 25px;">首页</a>
      </li>
       <li class="l-select">
       <a href="">销售查询</a>
       <span class="close"></span>
      </li>
     </ul>
    </div>

    <div class="l-tab-content" style="background:#fff;">
     <div class="tab-content-item">
      <div class="home">
      <!--库房分配   开始-->
        <div class="kufang-box">
         <div class="kufang">
         <div class="kf-fl">
          <ul>
           <li>门店编号：<span>${employees.eshopcode}</span></li>
          </ul>
         </div>

         <div class="kf-rg">
         <form action="">
          <ul>
           <li>
            <span>
             <select class="kf-in"  name="sales" id="sales">
             <script type="text/javascript"> 
              var sales='${sales}';
              var obj=document.getElementById("sales");
              if(sales==2){
             obj.add(new Option("销售日期","2"));
             obj.add(new Option("销售编号","1"));
        }else{
             obj.add(new Option("销售编号","1"));
             obj.add(new Option("销售日期","2"));
        }
             </script>
             </select>
             <input type="submit" value="查询" style="width: 40px;height: 23px;"/>
            </span>
           </li>
          </ul>
          </form>
         </div>
        </div>
       </div>
        
       <div class="kf-tab" style="height: 300px;">
        <div class="headerbar-kf">
         <table class="headerbar" border="0" cellpadding="0" cellspacing="1"  style="margin:0 auto;">
           <tr class="headerrow-kf">
            <td class="caption cao-l">
             <div class="caotion-kf-txt" style="overflow:hidden;text-align:center;width:85px;">销售单号</div>
            </td>
            <td class="caption cao-l"  >
             <div class="caotion-kf-txt" style="overflow:hidden;text-align:center;width:85px;" >商品名称</div>
            </td>
             <td class="caption cao-l">
             <div class="caotion-kf-txt" style="overflow:hidden;text-align:center;width:85px;">员工姓名</div>
            </td>
             <td class="caption cao-l" >
             <div class="caotion-kf-txt" style="overflow:hidden;text-align:center;width:85px;">会员卡号</div>
            </td>
             <td class="caption cao-l" >
             <div class="caotion-kf-txt" style="overflow:hidden;text-align:center;width:100px;">销售日期</div>
            </td>
             <td class="caption cao-l"  colspan="1" rowspan="1">
             <div class="caotion-kf-txt" style="overflow:hidden;text-align:center;width:85px;">数量</div>
            </td>
             <td class="caption cao-l"  colspan="1" rowspan="1">
             <div class="caotion-kf-txt" style="overflow:hidden;text-align:center;width:80px;">金额</div>
            </td> 
           </tr>
          <c:forEach var="sale" items="${saleslist}">
           <tr class="fkbody-s" rowindex="0">
            <td class="bodyrow-list"  _columnindex="0"  >
             <div class="bodytxt"  style="overflow:hidden;text-align:center; width:85px;">${sale.id}</div>
            </td>
            <td class="bodyrow-list"  _columnindex="0"  >
             <div class="bodytxt"  style="overflow:hidden;text-align:center; width:85px;">${sale.product.productname }</div>
            </td>
             <td class="bodyrow-list"_columnindex="1">
             <div class="bodytxt"  style="overflow:hidden;text-align:center; width:85px;">${sale.employees.name }</div>
            </td>
             <td class="bodyrow-list" _columnindex="4">
             <div class="bodytxt"  style="overflow:hidden;text-align:center; width:85px;">${sale.members.cardid}</div>
            </td>
             <td class="bodyrow-list"  _columnindex="5">
             <div class="bodytxt"  style="overflow:hidden;text-align: center; width:100px;"><fmt:formatDate value="${sale.saledate }" pattern="yyyy-MM-dd"/></div>
            </td>
             <td class="bodyrow-list" _columnindex="6">
             <div class="bodytxt"  style="overflow:hidden;text-align:right; width:85px;">${sale.salecount }</div>
            </td> 
            <td class="bodyrow-list" align _columnindex="7">
             <div class="bodytxt"  style="overflow:hidden;text-align:right; width:80px;">${sale.salesprice }</div>
            </td>
           </tr>
         </c:forEach>
         </table>
        </div>
        <div class="lu"> 
                 <span><a href="<%=basePath%>sales/saleslist.html?pageNo=1&sales=${sales }">首页</a></span>
				 <span><a href="<%=basePath%>sales/saleslist.html?pageNo=${pager.pageNo+1 }&sales=${sales }">下一页</a></span> 
				 <span><a href="<%=basePath%>sales/saleslist.html?pageNo=${pager.pageNo-1 }&sales=${sales }">上一页</a></span> 
				 <span><a href="<%=basePath%>sales/saleslist.html?pageNo=${pager.totalPage }&sales=${sales }">末页</a></span>            
                 <span>第${pager.pageNo}/${pager.totalPage }页&nbsp;</span>共<i>${pager.totalCount }</i>条记录</div>
       </div> 
       <div class="tab-btn">
        <div class="bt-rg">
         <ul>
         <li><a href="${pageContext.request.contextPath}/sales/salesadd.html"><button>添加</button></a></li>
          <li><button>打印</button></li>
         </ul>
        </div>
       </div>
      <!--库房分配   结束-->
      </div>      
     </div>
    </div>
   </div>

  </div>
 </div>
</div>
  
</body>
</html>
